const Controller = require("egg").Controller;

class NewsController extends Controller {
    async list() {
        const ctx = this.ctx;
        const page = ctx.query.apge || 1;
        const newsList = await ctx.service.news.list(page);

        await this.ctx.render('news/list.nj', { list: newsList });

    }
}
module.exports = NewsController;